const Koa=require('koa')

const app=new Koa()
app.use((ctx,next)=>{
    ctx.body={
        name:'zhangsan',
        age:20
    }
    
})

app.listen(8000,()=>{
    console.log("服务器启动成功")
})